package model;

import java.text.SimpleDateFormat;
import java.time.format.DateTimeFormatterBuilder;
import java.util.Date;

/**
 * @Question Record
 * @Date 2022/12/18 11:58
 * @Solution
 */
public class Record {
    private int id;
    private int bookId;
    private int userId;
    private Date outTime;
    private Date inTime;

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public int getBookId() {
        return bookId;
    }

    public void setBookId(int bookId) {
        this.bookId = bookId;
    }

    public int getUserId() {
        return userId;
    }

    public void setUserId(int userId) {
        this.userId = userId;
    }

    public Date getOutTime() {
        return outTime;
    }
    public String getStringOutTime() {
        SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyyMMddHHmmss");
        String fm = simpleDateFormat.format(outTime);
        return fm;
    }
    public void setOutTime(Date outTime) {
        this.outTime = outTime;
    }

    public Date getInTime() {
        return inTime;
    }
    public String getStringInTime() {
        SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyyMMddHHmmss");
        String fm = simpleDateFormat.format(inTime);
        return fm;
    }
    public void setInTime(Date inTime) {
        this.inTime = inTime;
    }
}
